package com.e2u.test.obj;

public class Singleton
{
	private static Singleton instance = null;
	private Singleton(){}
	
	public Singleton getInstance()
	{
		if(instance == null)
		{
			synchronized(Singleton.class)
			{
				if(instance == null)
				{
					instance = new Singleton();
				}				
			}
		}
		return instance;
	}
	
	public void sayHello()
	{
		System.out.println(getClass().getName() + " is Loaded by " + getClass().getClassLoader());
	}
}
